home *** CD-ROM | disk | FTP | other *** search
/ Programming Languages Suite / ProgLangD.iso / TURBOPASCAL WIN / OWLDEMOS.PAK / MDIAPP.PAS < prev    next >
Pascal/Delphi Source File  |  1992-06-08  |  974b  |  39 lines

  1. {************************************************}
  2. {                                                }
  3. {   Turbo Pascal for Windows                     }
  4. {   Demo program                                 }
  5. {   Copyright (c) 1991 by Borland International  }
  6. {                                                }
  7. {************************************************}
  8.  
  9. program MDI;
  10.  
  11. {$R MDIAPP.RES}
  12.                        
  13. uses WObjects, WinTypes, WinProcs;
  14.          
  15. type
  16.  
  17.   { Define a TApplication descendant } 
  18.   TMDIApp = object(TApplication)
  19.     procedure InitMainWindow; virtual;
  20.   end;
  21.  
  22. { Construct the THelloApp's MainWindow object, loading its menu }
  23. procedure TMDIApp.InitMainWindow;
  24. begin
  25.   MainWindow := New(PMDIWindow, Init('MDI Conformist',
  26.     LoadMenu(HInstance, 'MDIMenu')));
  27. end;
  28.  
  29. { Declare a variable of type TMDIApp} 
  30. var
  31.   MDIApp: TMDIApp;
  32.  
  33. { Run the MDIApp }
  34. begin
  35.   MDIApp.Init('MDIApp');
  36.   MDIApp.Run;
  37.   MDIApp.Done;
  38. end.
  39.